package com.leo;

import io.vertx.core.AbstractVerticle;

/**
 * @ClassName MyFirstVerticle
 * @Description
 * @Author wangss
 * @date 2020.11.27 17:38
 * @Version 1.0
 */
public class MyFirstVerticle extends AbstractVerticle {

    @Override
    public void start() throws Exception {
        vertx.createHttpServer().requestHandler(httpServerRequest -> {
            httpServerRequest.response().putHeader("content-type", "text/plain")
                    .end("Hello World!");
        }).listen(8081);
    }
}
